package com.foundersoftware.commons.organization.model;

import java.util.Date;
import java.util.Set;

public class Employee extends AbstractOrganizationObject {

	private static final long serialVersionUID = 2389494015230195798L;
	private String lastName;
    private String firstName;
    private String realName;
    private String surname;
    private boolean sex;
    private Date   birthday;
    private String email;
    private String displayName;
    private String employeeNumber;
    private String logonName;
    private String password;
    private Set<Address> addresses;
    private Set<EmailAddress> emails;

    public Date getBirthday() {
        return birthday;
    }

    public String getDisplayName() {
        return displayName;
    }

    public String getEmail() {
        return email;
    }

    public String getEmployeeNumber() {
        return employeeNumber;
    }

    public String getFirstName() {
        return firstName;
    }

    public String getLastName() {
        return lastName;
    }

    public String getLogonName() {
        return logonName;
    }

    public String getPassword() {
        return password;
    }

    public String getRealName() {
        return realName;
    }

    public boolean isSex() {
        return sex;
    }

    public String getSurname() {
        return surname;
    }


    public void setBirthday(Date birthday) {
        this.birthday = birthday;
    }

    public void setDisplayName(String displayName) {
        this.displayName = displayName;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public void setEmployeeNumber(String employeeNumber) {
        this.employeeNumber = employeeNumber;
    }

    public void setFirstName(String firstName) {
        this.firstName = firstName;
    }

    public void setLastName(String lastName) {
        this.lastName = lastName;
    }

    public void setLogonName(String logonName) {
        this.logonName = logonName;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public void setSex(boolean sex) {
        this.sex = sex;
    }

    public void setRealName(String realName) {
        this.realName = realName;
    }

    public void setSurname(String surname) {
        this.surname = surname;
    }

    public String toString() {
        return "Employee[id=" + getId()
                +",displayName="+getDisplayName()+
                "]";
    }

    public OrganizationUnit getOrganizationUnit() {
        return null;

    }

    public int hashCode() {
        return this.getId().hashCode();
    }

    public boolean equals(Object o) {

        if(o instanceof Employee) {
            Employee e = (Employee)o;
            return e.getId().equals(this.getId());
        } else {
            return false;
        }
    }

}
